//
//  NSString+Self_daptionHeight.m
//  片刻
//
//  Created by lanou3g on 15/6/7.
//  Copyright (c) 2015年 不成熟. All rights reserved.
//

#import "NSString+Self_daptionHeight.h"

@implementation NSString (Self_daptionHeight)
- (CGSize)sizeWithFont:(UIFont *)font maxSize:(CGSize)maxSize
{
    NSDictionary *attrs = @{NSFontAttributeName :font};
    return [self boundingRectWithSize:maxSize options:NSStringDrawingUsesLineFragmentOrigin attributes:attrs context:nil].size;
}
@end
